package learn_concurrent._1;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

public class T6 {
	final static Logger logger = LoggerFactory.getLogger(T6.class);
	
	public static void main(String[] args) {
		Thread t = new Thread() {
			public void run() {
				logger.info("run...");
				try {
					Thread.sleep(2000);
				} catch (InterruptedException e) {
					logger.info("wake...");
//					e.printStackTrace();
				}
			};
		};
		logger.info("{}", t.getState());
		t.start();
		logger.info("{}", t.getState());
		try {
			Thread.sleep(500);
		} catch (InterruptedException e) {
			e.printStackTrace();
		}
		logger.info("{}", t.getState());
		t.interrupt();
	}
	
	
}
